import { Component } from 'react'
import { View, Text } from '@tarojs/components'
import Taro from '@tarojs/taro'

const env = process.env.TARO_ENV

export default class Constant extends Component {

    state = {
        title: 'Constant页面'
    }

    componentDidMount() {
        console.log(`现在运行的环境：${env}`)
        console.log(`现在运行的环境：${Taro.ENV_TYPE.WEB}`)
        console.log(`现在运行的环境是h5吗？：${env == Taro.ENV_TYPE.WEB}`)
    }

    render() {
        return (
            <View >
                <Text >环境变量</Text>
            </View>
        )
    }

}
